package com.mgg.auth.social;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.security.web.authentication.AuthenticationSuccessHandler;
import org.springframework.social.security.SocialAuthenticationFilter;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;

@Component
public class SocialAuthenticationFilterPostProcesser {

	@Resource(name = "h5LoginAuthenticationSuccessHandler")
	protected AuthenticationSuccessHandler h5LoginAutenticationSuccessHandler;

	public void process(SocialAuthenticationFilter socialAuthenticationFilter) {
		socialAuthenticationFilter.setAuthenticationSuccessHandler(h5LoginAutenticationSuccessHandler);
	}
}
